Optimal. Leaf size=263 \[ -\frac {a x}{b^3}+\frac {(a+b x)^2}{12 b^4}+\frac {a \tanh ^{-1}(a+b x)}{b^4}+\frac {\left (1+6 a^2\right ) (a+b x) \tanh ^{-1}(a+b x)}{2 b^4}-\frac {a (a+b x)^2 \tanh ^{-1}(a+b x)}{b^4}+\frac {(a+b x)^3 \tanh ^{-1}(a+b x)}{6 b^4}-\frac {a \left (1+a^2\right ) \tanh ^{-1}(a+b x)^2}{b^4}-\frac {\left (1+6 a^2+a^4\right ) \tanh ^{-1}(a+b x)^2}{4 b^4}+\frac {1}{4} x^4 \tanh ^{-1}(a+b x)^2+\frac {2 a \left (1+a^2\right ) \tanh ^{-1}(a+b x) \log \left (\frac {2}{1-a-b x}\right )}{b^4}+\frac {\log \left (1-(a+b x)^2\right )}{12 b^4}+\frac {\left (1+6 a^2\right ) \log \left (1-(a+b x)^2\right )}{4 b^4}+\frac {a \left (1+a^2\right ) \text {PolyLog}\left (2,-\frac {1+a+b x}{1-a-b x}\right )}{b^4} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.24, antiderivative size = 263, normalized size of antiderivative = 1.00, number of steps
used = 19, number of rules used = 15, integrand size = 12, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 1.250, Rules used =
{6246, 6065, 6021, 266, 6037, 327, 212, 272, 45, 6195, 6095, 6131, 6055, 2449, 2352}
\begin {gather*} \frac {a \left (a^2+1\right ) \text {Li}_2\left (-\frac {a+b x+1}{-a-b x+1}\right )}{b^4}+\frac {\left (6 a^2+1\right ) \log \left (1-(a+b x)^2\right )}{4 b^4}-\frac {a \left (a^2+1\right ) \tanh ^{-1}(a+b x)^2}{b^4}+\frac {\left (6 a^2+1\right ) (a+b x) \tanh ^{-1}(a+b x)}{2 b^4}+\frac {2 a \left (a^2+1\right ) \log \left (\frac {2}{-a-b x+1}\right ) \tanh ^{-1}(a+b x)}{b^4}-\frac {\left (a^4+6 a^2+1\right ) \tanh ^{-1}(a+b x)^2}{4 b^4}+\frac {(a+b x)^2}{12 b^4}+\frac {\log \left (1-(a+b x)^2\right )}{12 b^4}+\frac {(a+b x)^3 \tanh ^{-1}(a+b x)}{6 b^4}-\frac {a (a+b x)^2 \tanh ^{-1}(a+b x)}{b^4}+\frac {a \tanh ^{-1}(a+b x)}{b^4}-\frac {a x}{b^3}+\frac {1}{4} x^4 \tanh ^{-1}(a+b x)^2 \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 45
Rule 212
Rule 266
Rule 272
Rule 327
Rule 2352
Rule 2449
Rule 6021
Rule 6037
Rule 6055
Rule 6065
Rule 6095
Rule 6131
Rule 6195
Rule 6246
Rubi steps
\begin {align*} \int x^3 \tanh ^{-1}(a+b x)^2 \, dx &=\frac {\text {Subst}\left (\int \left (-\frac {a}{b}+\frac {x}{b}\right )^3 \tanh ^{-1}(x)^2 \, dx,x,a+b x\right )}{b}\\ &=\frac {1}{4} x^4 \tanh ^{-1}(a+b x)^2-\frac {1}{2} \text {Subst}\left (\int \left (-\frac {\left (1+6 a^2\right ) \tanh ^{-1}(x)}{b^4}+\frac {4 a x \tanh ^{-1}(x)}{b^4}-\frac {x^2 \tanh ^{-1}(x)}{b^4}+\frac {\left (1+6 a^2+a^4-4 a \left (1+a^2\right ) x\right ) \tanh ^{-1}(x)}{b^4 \left (1-x^2\right )}\right ) \, dx,x,a+b x\right )\\ &=\frac {1}{4} x^4 \tanh ^{-1}(a+b x)^2+\frac {\text {Subst}\left (\int x^2 \tanh ^{-1}(x) \, dx,x,a+b x\right )}{2 b^4}-\frac {\text {Subst}\left (\int \frac {\left (1+6 a^2+a^4-4 a \left (1+a^2\right ) x\right ) \tanh ^{-1}(x)}{1-x^2} \, dx,x,a+b x\right )}{2 b^4}-\frac {(2 a) \text {Subst}\left (\int x \tanh ^{-1}(x) \, dx,x,a+b x\right )}{b^4}+\frac {\left (1+6 a^2\right ) \text {Subst}\left (\int \tanh ^{-1}(x) \, dx,x,a+b x\right )}{2 b^4}\\ &=\frac {\left (1+6 a^2\right ) (a+b x) \tanh ^{-1}(a+b x)}{2 b^4}-\frac {a (a+b x)^2 \tanh ^{-1}(a+b x)}{b^4}+\frac {(a+b x)^3 \tanh ^{-1}(a+b x)}{6 b^4}+\frac {1}{4} x^4 \tanh ^{-1}(a+b x)^2-\frac {\text {Subst}\left (\int \frac {x^3}{1-x^2} \, dx,x,a+b x\right )}{6 b^4}-\frac {\text {Subst}\left (\int \left (\frac {\left (1+a^2 \left (6+a^2\right )\right ) \tanh ^{-1}(x)}{1-x^2}-\frac {4 a \left (1+a^2\right ) x \tanh ^{-1}(x)}{1-x^2}\right ) \, dx,x,a+b x\right )}{2 b^4}+\frac {a \text {Subst}\left (\int \frac {x^2}{1-x^2} \, dx,x,a+b x\right )}{b^4}-\frac {\left (1+6 a^2\right ) \text {Subst}\left (\int \frac {x}{1-x^2} \, dx,x,a+b x\right )}{2 b^4}\\ &=-\frac {a x}{b^3}+\frac {\left (1+6 a^2\right ) (a+b x) \tanh ^{-1}(a+b x)}{2 b^4}-\frac {a (a+b x)^2 \tanh ^{-1}(a+b x)}{b^4}+\frac {(a+b x)^3 \tanh ^{-1}(a+b x)}{6 b^4}+\frac {1}{4} x^4 \tanh ^{-1}(a+b x)^2+\frac {\left (1+6 a^2\right ) \log \left (1-(a+b x)^2\right )}{4 b^4}-\frac {\text {Subst}\left (\int \frac {x}{1-x} \, dx,x,(a+b x)^2\right )}{12 b^4}+\frac {a \text {Subst}\left (\int \frac {1}{1-x^2} \, dx,x,a+b x\right )}{b^4}+\frac {\left (2 a \left (1+a^2\right )\right ) \text {Subst}\left (\int \frac {x \tanh ^{-1}(x)}{1-x^2} \, dx,x,a+b x\right )}{b^4}-\frac {\left (1+6 a^2+a^4\right ) \text {Subst}\left (\int \frac {\tanh ^{-1}(x)}{1-x^2} \, dx,x,a+b x\right )}{2 b^4}\\ &=-\frac {a x}{b^3}+\frac {a \tanh ^{-1}(a+b x)}{b^4}+\frac {\left (1+6 a^2\right ) (a+b x) \tanh ^{-1}(a+b x)}{2 b^4}-\frac {a (a+b x)^2 \tanh ^{-1}(a+b x)}{b^4}+\frac {(a+b x)^3 \tanh ^{-1}(a+b x)}{6 b^4}-\frac {a \left (1+a^2\right ) \tanh ^{-1}(a+b x)^2}{b^4}-\frac {\left (1+6 a^2+a^4\right ) \tanh ^{-1}(a+b x)^2}{4 b^4}+\frac {1}{4} x^4 \tanh ^{-1}(a+b x)^2+\frac {\left (1+6 a^2\right ) \log \left (1-(a+b x)^2\right )}{4 b^4}-\frac {\text {Subst}\left (\int \left (-1+\frac {1}{1-x}\right ) \, dx,x,(a+b x)^2\right )}{12 b^4}+\frac {\left (2 a \left (1+a^2\right )\right ) \text {Subst}\left (\int \frac {\tanh ^{-1}(x)}{1-x} \, dx,x,a+b x\right )}{b^4}\\ &=-\frac {a x}{b^3}+\frac {(a+b x)^2}{12 b^4}+\frac {a \tanh ^{-1}(a+b x)}{b^4}+\frac {\left (1+6 a^2\right ) (a+b x) \tanh ^{-1}(a+b x)}{2 b^4}-\frac {a (a+b x)^2 \tanh ^{-1}(a+b x)}{b^4}+\frac {(a+b x)^3 \tanh ^{-1}(a+b x)}{6 b^4}-\frac {a \left (1+a^2\right ) \tanh ^{-1}(a+b x)^2}{b^4}-\frac {\left (1+6 a^2+a^4\right ) \tanh ^{-1}(a+b x)^2}{4 b^4}+\frac {1}{4} x^4 \tanh ^{-1}(a+b x)^2+\frac {2 a \left (1+a^2\right ) \tanh ^{-1}(a+b x) \log \left (\frac {2}{1-a-b x}\right )}{b^4}+\frac {\log \left (1-(a+b x)^2\right )}{12 b^4}+\frac {\left (1+6 a^2\right ) \log \left (1-(a+b x)^2\right )}{4 b^4}-\frac {\left (2 a \left (1+a^2\right )\right ) \text {Subst}\left (\int \frac {\log \left (\frac {2}{1-x}\right )}{1-x^2} \, dx,x,a+b x\right )}{b^4}\\ &=-\frac {a x}{b^3}+\frac {(a+b x)^2}{12 b^4}+\frac {a \tanh ^{-1}(a+b x)}{b^4}+\frac {\left (1+6 a^2\right ) (a+b x) \tanh ^{-1}(a+b x)}{2 b^4}-\frac {a (a+b x)^2 \tanh ^{-1}(a+b x)}{b^4}+\frac {(a+b x)^3 \tanh ^{-1}(a+b x)}{6 b^4}-\frac {a \left (1+a^2\right ) \tanh ^{-1}(a+b x)^2}{b^4}-\frac {\left (1+6 a^2+a^4\right ) \tanh ^{-1}(a+b x)^2}{4 b^4}+\frac {1}{4} x^4 \tanh ^{-1}(a+b x)^2+\frac {2 a \left (1+a^2\right ) \tanh ^{-1}(a+b x) \log \left (\frac {2}{1-a-b x}\right )}{b^4}+\frac {\log \left (1-(a+b x)^2\right )}{12 b^4}+\frac {\left (1+6 a^2\right ) \log \left (1-(a+b x)^2\right )}{4 b^4}+\frac {\left (2 a \left (1+a^2\right )\right ) \text {Subst}\left (\int \frac {\log (2 x)}{1-2 x} \, dx,x,\frac {1}{1-a-b x}\right )}{b^4}\\ &=-\frac {a x}{b^3}+\frac {(a+b x)^2}{12 b^4}+\frac {a \tanh ^{-1}(a+b x)}{b^4}+\frac {\left (1+6 a^2\right ) (a+b x) \tanh ^{-1}(a+b x)}{2 b^4}-\frac {a (a+b x)^2 \tanh ^{-1}(a+b x)}{b^4}+\frac {(a+b x)^3 \tanh ^{-1}(a+b x)}{6 b^4}-\frac {a \left (1+a^2\right ) \tanh ^{-1}(a+b x)^2}{b^4}-\frac {\left (1+6 a^2+a^4\right ) \tanh ^{-1}(a+b x)^2}{4 b^4}+\frac {1}{4} x^4 \tanh ^{-1}(a+b x)^2+\frac {2 a \left (1+a^2\right ) \tanh ^{-1}(a+b x) \log \left (\frac {2}{1-a-b x}\right )}{b^4}+\frac {\log \left (1-(a+b x)^2\right )}{12 b^4}+\frac {\left (1+6 a^2\right ) \log \left (1-(a+b x)^2\right )}{4 b^4}+\frac {a \left (1+a^2\right ) \text {Li}_2\left (1-\frac {2}{1-a-b x}\right )}{b^4}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 1.28, size = 187, normalized size = 0.71 \begin {gather*} -\frac {1+11 a^2+10 a b x-b^2 x^2+3 \left (1-4 a+6 a^2-4 a^3+a^4-b^4 x^4\right ) \tanh ^{-1}(a+b x)^2-2 \tanh ^{-1}(a+b x) \left (9 a+13 a^3+3 b x+9 a^2 b x-3 a b^2 x^2+b^3 x^3+12 \left (a+a^3\right ) \log \left (1+e^{-2 \tanh ^{-1}(a+b x)}\right )\right )+8 \log \left (\frac {1}{\sqrt {1-(a+b x)^2}}\right )+36 a^2 \log \left (\frac {1}{\sqrt {1-(a+b x)^2}}\right )+12 \left (a+a^3\right ) \text {PolyLog}\left (2,-e^{-2 \tanh ^{-1}(a+b x)}\right )}{12 b^4} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(886\) vs.
\(2(251)=502\).
time = 2.18, size = 887, normalized size = 3.37
method | result | size |
derivativedivides | \(\text {Expression too large to display}\) | \(887\) |
default | \(\text {Expression too large to display}\) | \(887\) |
risch | \(-\frac {1}{12 b^{4}}-\frac {5 a x}{6 b^{3}}-\frac {\ln \left (-b x -a +1\right ) \left (-b x -a +1\right )^{3}}{12 b^{4}}+\frac {\ln \left (-b x -a +1\right ) \left (-b x -a +1\right )^{2}}{8 b^{4}}+\frac {13 \ln \left (-b x -a -1\right ) a^{3}}{12 b^{4}}-\frac {\left (-b^{4} x^{4}+a^{4}+4 a^{3}+6 a^{2}+4 a +1\right ) \ln \left (b x +a +1\right )^{2}}{16 b^{4}}+\frac {3 \ln \left (-b x -a -1\right ) a^{2}}{2 b^{4}}+\frac {3 \ln \left (-b x -a -1\right ) a}{4 b^{4}}+\frac {\ln \left (-b x -a +1\right ) \left (-b x -a +1\right )^{4}}{32 b^{4}}+\frac {\ln \left (-b x -a -1\right )}{3 b^{4}}+\left (-\frac {x^{4} \ln \left (-b x -a +1\right )}{8}-\frac {-2 x^{3} b^{3}-3 \ln \left (-b x -a +1\right ) a^{4}+6 a \,b^{2} x^{2}+12 \ln \left (-b x -a +1\right ) a^{3}-18 a^{2} b x -18 \ln \left (-b x -a +1\right ) a^{2}+12 \ln \left (-b x -a +1\right ) a -6 b x -3 \ln \left (-b x -a +1\right )}{24 b^{4}}\right ) \ln \left (b x +a +1\right )+\frac {a}{b^{4}}-\frac {11 a^{2}}{12 b^{4}}+\frac {x^{2}}{12 b^{2}}+\frac {25 \ln \left (-b x -a +1\right )}{96 b^{4}}-\frac {\ln \left (-b x -a +1\right )^{2}}{16 b^{4}}+\frac {\ln \left (-b x -a +1\right )^{2} x^{4}}{16}+\frac {\ln \left (-b x -a +1\right ) \left (-b x -a +1\right )^{3} a}{6 b^{4}}+\frac {3 \ln \left (-b x -a +1\right ) \left (-b x -a +1\right )^{2} a^{2}}{8 b^{4}}-\frac {\ln \left (-b x -a +1\right ) \left (-b x -a +1\right )^{2} a}{4 b^{4}}+\frac {\ln \left (-b x -a +1\right ) \left (-b x -a +1\right ) a^{3}}{2 b^{4}}+\frac {\ln \left (-b x -a +1\right ) \left (-b x -a +1\right ) a}{2 b^{4}}+\frac {\ln \left (-b x -a +1\right ) \ln \left (\frac {b x}{2}+\frac {a}{2}+\frac {1}{2}\right ) a^{3}}{b^{4}}-\frac {\ln \left (-\frac {b x}{2}-\frac {a}{2}+\frac {1}{2}\right ) \ln \left (\frac {b x}{2}+\frac {a}{2}+\frac {1}{2}\right ) a^{3}}{b^{4}}+\frac {\ln \left (-b x -a +1\right ) \ln \left (\frac {b x}{2}+\frac {a}{2}+\frac {1}{2}\right ) a}{b^{4}}-\frac {\ln \left (-\frac {b x}{2}-\frac {a}{2}+\frac {1}{2}\right ) \ln \left (\frac {b x}{2}+\frac {a}{2}+\frac {1}{2}\right ) a}{b^{4}}+\frac {\ln \left (-b x -a +1\right ) x^{2} a}{8 b^{2}}-\frac {3 \ln \left (-b x -a +1\right ) x \,a^{2}}{8 b^{3}}+\frac {3 \ln \left (-b x -a +1\right ) x a}{8 b^{3}}-\frac {\ln \left (-b x -a +1\right ) x^{2} a^{2}}{16 b^{2}}+\frac {\ln \left (-b x -a +1\right ) x \,a^{3}}{8 b^{3}}+\frac {a \ln \left (-b x -a +1\right ) x^{3}}{24 b}-\frac {\ln \left (-b x -a +1\right ) x^{3}}{24 b}-\frac {\ln \left (-b x -a +1\right ) x^{2}}{16 b^{2}}-\frac {\ln \left (-b x -a +1\right ) x}{8 b^{3}}+\frac {\ln \left (-b x -a +1\right )^{2} a^{3}}{4 b^{4}}-\frac {3 \ln \left (-b x -a +1\right )^{2} a^{2}}{8 b^{4}}+\frac {\ln \left (-b x -a +1\right )^{2} a}{4 b^{4}}-\frac {25 \ln \left (-b x -a +1\right ) a^{3}}{24 b^{4}}+\frac {25 \ln \left (-b x -a +1\right ) a^{2}}{16 b^{4}}-\frac {25 \ln \left (-b x -a +1\right ) a}{24 b^{4}}-\frac {\ln \left (-b x -a +1\right )^{2} a^{4}}{16 b^{4}}+\frac {25 \ln \left (-b x -a +1\right ) a^{4}}{96 b^{4}}-\frac {x^{4} \ln \left (-b x -a +1\right )}{32}-\frac {\dilog \left (-\frac {b x}{2}-\frac {a}{2}+\frac {1}{2}\right ) a^{3}}{b^{4}}-\frac {\dilog \left (-\frac {b x}{2}-\frac {a}{2}+\frac {1}{2}\right ) a}{b^{4}}\) | \(1001\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.27, size = 320, normalized size = 1.22 \begin {gather*} \frac {1}{4} \, x^{4} \operatorname {artanh}\left (b x + a\right )^{2} + \frac {1}{48} \, b^{2} {\left (\frac {48 \, {\left (a^{3} + a\right )} {\left (\log \left (b x + a - 1\right ) \log \left (\frac {1}{2} \, b x + \frac {1}{2} \, a + \frac {1}{2}\right ) + {\rm Li}_2\left (-\frac {1}{2} \, b x - \frac {1}{2} \, a + \frac {1}{2}\right )\right )}}{b^{6}} + \frac {4 \, {\left (13 \, a^{3} + 18 \, a^{2} + 9 \, a + 4\right )} \log \left (b x + a + 1\right )}{b^{6}} + \frac {4 \, b^{2} x^{2} - 40 \, a b x + 3 \, {\left (a^{4} + 4 \, a^{3} + 6 \, a^{2} + 4 \, a + 1\right )} \log \left (b x + a + 1\right )^{2} - 6 \, {\left (a^{4} + 4 \, a^{3} + 6 \, a^{2} + 4 \, a + 1\right )} \log \left (b x + a + 1\right ) \log \left (b x + a - 1\right ) + 3 \, {\left (a^{4} - 4 \, a^{3} + 6 \, a^{2} - 4 \, a + 1\right )} \log \left (b x + a - 1\right )^{2} - 4 \, {\left (13 \, a^{3} - 18 \, a^{2} + 9 \, a - 4\right )} \log \left (b x + a - 1\right )}{b^{6}}\right )} + \frac {1}{12} \, b {\left (\frac {2 \, {\left (b^{2} x^{3} - 3 \, a b x^{2} + 3 \, {\left (3 \, a^{2} + 1\right )} x\right )}}{b^{4}} - \frac {3 \, {\left (a^{4} + 4 \, a^{3} + 6 \, a^{2} + 4 \, a + 1\right )} \log \left (b x + a + 1\right )}{b^{5}} + \frac {3 \, {\left (a^{4} - 4 \, a^{3} + 6 \, a^{2} - 4 \, a + 1\right )} \log \left (b x + a - 1\right )}{b^{5}}\right )} \operatorname {artanh}\left (b x + a\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int x^{3} \operatorname {atanh}^{2}{\left (a + b x \right )}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.00 \begin {gather*} \int x^3\,{\mathrm {atanh}\left (a+b\,x\right )}^2 \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________